from django.urls import path
from rest_framework_simplejwt.views import TokenRefreshView, TokenVerifyView
from user.utils.authentication import AVTokenObtainPairView
from user import views
from user.views import TestView

urlpatterns = [
    path('register/', views.RegisterView.as_view(), name='register'), # 注册
    # path('login/', views.LoginView.as_view(), name='login'), # 登录
    path('login/', AVTokenObtainPairView.as_view()),
    path('refresh/', TokenRefreshView.as_view(), name='token_refresh'),
    path('verify/', TokenVerifyView.as_view(), name='token_verify' ),
    path('info/', views.UserInfoView.as_view(), name='info'), # 获取用户信息
    path('update/', views.UserUpdateView.as_view(), name='update'), # 更新用户信息
    path('test/', TestView.as_view(), name='test'),
]